package cn.yuanqiao.activiti.service;

import cn.yuanqiao.common.core.domain.R;
import cn.yuanqiao.common.utils.file.FileUtils;
import cn.yuanqiao.system.domain.SysFile;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.core.io.Resource;
import org.springframework.http.ResponseEntity;
import org.springframework.web.multipart.MultipartFile;

import java.io.UnsupportedEncodingException;

/**
 * 文件上传接口
 * 
 * @author ruoyi
 */
public interface ISysFileService
{

    /**
     * 文件上传接口
     * 
     * @param file 上传的文件
     * @return 访问地址
     * @throws Exception
     */
    public String uploadFile(MultipartFile file) throws Exception;

    public R<SysFile> upload(MultipartFile file);

    ResponseEntity<Resource> statics(String path) throws UnsupportedEncodingException;
}
